package com.atguigu.gulimall.product.service;

import com.atguigu.gulimall.product.vo.Catalog2VO;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.product.entity.CategoryEntity;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author biubiu0002
 * @email 1007918011@qq.com
 * @date 2021-05-23 12:14:36
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);

    List<CategoryEntity> listWithTree();

    void removeMenuByIds(List<Long> asList);

    /**
     * 找到catlogId的完整路径
     * [父,子,孙]
     * @param categoryId
     * @return
     */
    Long[] findCategoryPath(long categoryId);

    void updateCascade(CategoryEntity category);

    List<CategoryEntity> getLevel1Categories();

    Map<String, List<Catalog2VO>> getCatalogJSON();
}

